import React,{Fragment} from 'react';
import {Route} from 'react-router-dom';
import Home from './containers/Home';
import User from './containers/User';
import UserList from './containers/User/components/UserList';
import Counter from './containers/Counter';
import App from './containers/App';
import Login from './containers/Login';
import Logout from './containers/Logout';
import Profile from './containers/Profile';
import NotFound from './containers/NotFound';
export default [
	{
		path: '/',
		component: App,
		loadData:App.loadData,
		routes: [
			{
				path: '/',
				component: Home,
				exact: true,
				key:'/home',
				loadData:Home.loadData
			},
			{
				path: '/user',
				component: User,
				key: '/user',
				routes: [
					{
						path: '/user/list',
						component: UserList,
						key:'/user/list'
					}
				]
			},
			{
				path: '/counter',
				component: Counter,
				key:'login',
				exact: true
			},
			{
				path: '/login',
				component: Login,
				key:'/login',
				exact: true
			},
			{
				path: '/logout',
				component: Logout,
				key:'/logout',
				exact: true
			},
			{
				path: '/profile',
				component: Profile,
				key:'/profile',
				exact: true
			},
			{
				component: NotFound
			}
		]
	}
	
]